package cn.appsys.service.devuser;

import java.util.Date;
import java.util.List;

import org.apache.ibatis.annotations.Param;

import cn.appsys.pojo.AppInfo;

public interface AppInfoService {

	/**
	 * 查询app列表
	 * 
	 * @author chenglong
	 * @param querySoftwareName
	 * @param queryStatus
	 * @param queryCategoryLevel1
	 * @param queryCategoryLevel2
	 * @param queryCategoryLevel3
	 * @param queryFlatformId
	 * @param devId
	 * @param currentPageNo
	 * @param pageSize
	 * @return
	 * @throws Exception
	 */
	public List<AppInfo> getAppInfoList(String querySoftwareName, Integer queryStatus, Integer queryCategoryLevel1,
			Integer queryCategoryLevel2, Integer queryCategoryLevel3, Integer queryFlatformId, Integer devId,
			Integer currentPageNo, Integer pageSize) throws Exception;

	/**
	 * 根据条件查询appInfo表记录数
	 * 
	 * @param querySoftwareName
	 * @param queryStatus
	 * @param queryCategoryLevel1
	 * @param queryCategoryLevel2
	 * @param queryCategoryLevel3
	 * @param queryFlatformId
	 * @param devId
	 * @return
	 * @throws Exception
	 */
	public int getAppInfoCount(String querySoftwareName, Integer queryStatus, Integer queryCategoryLevel1,
			Integer queryCategoryLevel2, Integer queryCategoryLevel3, Integer queryFlatformId, Integer devId)
			throws Exception;

	/**
	 * @author chenglong
	 * @param AppInfo
	 * @return
	 * @throws Exception
	 */
	public boolean addAppInfo(AppInfo appinfo) throws Exception;

	/**
	 * 修改appinfo审核状态
	 */
	int updateAppStatus(Integer id, Integer status, Integer modifyByid, Date date);

	/**
	 * 删除app_version表中的版本信息，在删除app_info的信息
	 * 
	 * @author chenglong
	 * @param appversionid[]
	 * @param appinfoid
	 */
	public boolean delAppinfo(Integer appinfoid);

	public AppInfo getAppInfo(Integer id);

	/**
	 * 根据id获取appinfo
	 */
	AppInfo getAppInfobyId(Integer id);

	/**
	 * 修改app信息
	 */
	int updateAppInfo(AppInfo appInfo);
}